<?php

/**
 * @Author: kendy
 * @Date:   2020-01-02 10:07:57
 * @Last Modified by:   jiayanting
 * @Last Modified time: 2020-01-02 11:12:55
 */

namespace app\common\model;

use think\Db;
use think\Model;
/**
 * Class OrderCancelModel
 * @package app\common\model\OrderCancelModel
 * 订单核销类
 */
class OrderCancelModel extends Model
{
	  // 数据库表名
    protected $table = 'order_cancel';
 /**
  * [orderCancel 订单核销表]
  * @Author   kendy
  * @DateTime 2020-01-02T10:11:34+0800
  * @param    [type]                   $cancelId [核销人id]
  * @param    [type]                   $type     [1景点 2酒店 3旅行社]
  * @param    [type]                   $orderId  [订单ID]
  * @param    [type]                   $orderSn  [订单编号]
  * @return   [type]                             [description]
  */
  public function orderCancel($cancelId,$type,$orderId,$orderSn,$money)
  {
           $orderCancel['cancel_id'] = $cancelId;
           $orderCancel['order_sn'] = $orderSn;
           $orderCancel['order_id'] = $orderId; 
           $orderCancel['type'] = $type;
           $orderCancel['create_time'] = date('Y-m-d H:i:s',time());
           $orderCancel['money'] = $money;
           Db::name($this->table)->insert($orderCancel);

  }

}